<style>
.taskSearchRow{
	width:95%; float:left; height:30px; line-height:30px; vertical-align:middle;
}
.taskSearchRowItem1{
	width:33%; float:left; font-weight:bold;
}
.taskSearchRowItem2{
	width:50%; float:left; font-weight:bold;
}

</style>
<div class="wide form">

<?php $form=$this->beginWidget('CActiveForm', array(
        'htmlOptions' => array('name'=>'taskSearch'),
	'action'=>Yii::app()->createUrl($this->route),
	'method'=>'get',
)); ?>
	<div style="width:100%; padding-left:5%">
    	<div class="taskSearchRow">
            <div class="taskSearchRowItem1">Tcode: <?php echo $form->textField($model,'tcode',array('size'=>15,'style'=>'margin:0 0 0 10px;')); ?></div>
            <div class="taskSearchRowItem1">Subcode: <?php echo $form->textField($model,'subcode',array('size'=>15,'style'=>'margin:0 0 0 10px;')); ?></div>
            <div class="taskSearchRowItem1">Office: <?php echo $form->dropDownList($model,'office',array(''=>'All','TB'=>'TB','PM'=>'PM','MX'=>'MX'),array('style'=>'margin:0 0 0 20px;')); ?></div>
        </div>
		<div class="taskSearchRow">
            <div class="taskSearchRowItem1">Tco: <?php echo $form->textField($model,'tco',array('size'=>15,'style'=>'margin:0 0 0 25px;')); ?></div>
            <div class="taskSearchRowItem1">Sco: <?php echo $form->textField($model,'sco',array('size'=>15,'style'=>'margin:0 0 0 42px;')); ?></div>
            <div class="taskSearchRowItem1">Periodic: <?php echo $form->dropDownList($model,'periodic',array(''=>'All','O'=>'Once','S'=>'Shift','D'=>'Day','W'=>'Week','M'=>'Month','Y'=>'Year'),array('style'=>'margin:0 0 0 6px;')); ?></div>
        </div>
        <div class="taskSearchRow">
            <div class="taskSearchRowItem1">权重: <?php echo $form->textField($model,'urgency',array('size'=>15,'style'=>'margin:0 0 0 20px;')); ?></div>
            <div class="taskSearchRowItem1">完成度: <?php echo $form->textField($model,'sco',array('size'=>15,'style'=>'margin:0 0 0 25px;')); ?></div>
            <div class="taskSearchRowItem1">创建人: <?php echo $form->textField($model,'created_by',array('size'=>10,'style'=>'margin:0 0 0 16px;')); ?></div>
        </div>
        <div class="taskSearchRow">
            <div class="taskSearchRowItem1">跟进人: <?php echo $form->textField($model,'follow_up_person',array('size'=>15,'style'=>'margin:0 0 0 6px;')); ?></div>
            <div class="taskSearchRowItem1">跟进时间: <?php echo $form->textField($model,'follow_up_date',array('size'=>15,'style'=>'margin:0 0 0 12px;')); ?></div>
            <div class="taskSearchRowItem1">修改人: <?php echo $form->textField($model,'updated_by',array('size'=>10,'style'=>'margin:0 0 0 16px;')); ?></div>
        </div>
        <div class="taskSearchRow">
            <div class="taskSearchRowItem2">Start Date: <?php echo CHtml::textField('estart1',$timeFilter["estart1"]?date("Ymd",$timeFilter["estart1"]):'',array('size'=>8,'style'=>'margin:0 0 0 6px;')); ?><?php echo CHtml::button('estart1s',array('style'=>'width:30px;','value'=>'Cal','onclick'=>'displayCalendar(document.taskSearch.estart1,"yyyymmdd",this)')); ?><?php echo CHtml::textField('estart2',$timeFilter["estart2"]?date("Ymd",$timeFilter["estart2"]):'',array('size'=>8,'style'=>'margin:0 0 0 6px;')); ?><?php echo CHtml::button('estart2s',array('style'=>'width:30px;','value'=>'Cal','onclick'=>'displayCalendar(document.taskSearch.estart2,"yyyymmdd",this)')); ?></div>
            <div class="taskSearchRowItem2">End Date: <?php echo CHtml::textField('eend1',$timeFilter["eend1"]?date("Ymd",$timeFilter["eend1"]):'',array('size'=>8,'style'=>'margin:0 0 0 6px;')); ?><?php echo CHtml::button('eend2s',array('style'=>'width:30px;','value'=>'Cal','onclick'=>'displayCalendar(document.taskSearch.eend1,"yyyymmdd",this)')); ?><?php echo CHtml::textField('eend2',$timeFilter["eend2"]?date("Ymd",$timeFilter["eend2"]):'',array('size'=>8,'style'=>'margin:0 0 0 6px;')); ?><?php echo CHtml::button('eend2s',array('style'=>'width:30px;','value'=>'Cal','onclick'=>'displayCalendar(document.taskSearch.eend2,"yyyymmdd",this)')); ?></div>
        </div>
         <div class="taskSearchRow">
            <div class="taskSearchRowItem2">R Start Date: <?php echo CHtml::textField('rstart1',$timeFilter["estart1"]?date("Ymd",$timeFilter["rstart1"]):'',array('size'=>8,'style'=>'margin:0 0 0 6px;')); ?><?php echo CHtml::button('rstart1s',array('style'=>'width:30px;','value'=>'Cal','onclick'=>'displayCalendar(document.taskSearch.rstart1,"yyyymmdd",this)')); ?><?php echo CHtml::textField('rstart2',$timeFilter["estart2"]?date("Ymd",$timeFilter["rstart2"]):'',array('size'=>8,'style'=>'margin:0 0 0 6px;')); ?><?php echo CHtml::button('rstart2s',array('style'=>'width:30px;','value'=>'Cal','onclick'=>'displayCalendar(document.taskSearch.rstart2,"yyyymmdd",this)')); ?></div>
            <div class="taskSearchRowItem2">R End Date: <?php echo CHtml::textField('rend1',$timeFilter["rend1"]?date("Ymd",$timeFilter["rend1"]):'',array('size'=>8,'style'=>'margin:0 0 0 6px;')); ?><?php echo CHtml::button('rend1s',array('style'=>'width:30px;','value'=>'Cal','onclick'=>'displayCalendar(document.taskSearch.rend1,"yyyymmdd",this)')); ?><?php echo CHtml::textField('rend2',$timeFilter["rend2"]?date("Ymd",$timeFilter["rend2"]):'',array('size'=>8,'style'=>'margin:0 0 0 6px;')); ?><?php echo CHtml::button('rend2s',array('style'=>'width:30px;','value'=>'Cal','onclick'=>'displayCalendar(document.taskSearch.rend2,"yyyymmdd",this)')); ?></div>
        </div>
	</div>
	
	<div class="row buttons" style="padding:10px 0 0 0;" align="center">
		<?php echo CHtml::submitButton('Search'); ?>
	</div>

<?php $this->endWidget(); ?>

</div><!-- search-form -->